<br/>
<br/>
<div class="tabs_link_area menu">
    <ul>
        <li class="menu_item"><a href="javascript:void(0)" component="assigned_programs" class=<?php if($component == 'assigned_programs') echo 'active' ?> id="tab_link_1" onclick=""><?php echo __('my assigned programs'); ?></a></li>
        <li class="menu_item"><a href="javascript:void(0)" component="opened_night_programs" class=<?php if($component == 'opened_night_programs') echo 'active' ?> id="tab_link_2" onclick=""><?php echo __('Opened NIGHT programs'); ?></a></li>
        <li class="menu_item"><a href="javascript:void(0)" component="long_term_programs" class=<?php if($component == 'long_term_programs') echo 'active' ?> id="tab_link_3" onclick=""><?php echo __('Opened Long term programs'); ?></a></li>            
    </ul>
</div>

<div class="clear"></div>    

<div id="component_holder">
    <?php if($component !== false) { ?>
    <?php include_component('home', $component) ?>
    <?php } else { ?>
    <?php include_component('home', 'assigned_programs') ?>
    <?php } ?>
</div>

<script>
    jQuery('.tabs_link_area a').each(function(k,v){
        jQuery(v).click(function(){
            component = $(this).attr('component');
            if(component == 'none') return false;
            jQuery('.tabs_link_area a').removeClass('active');
            jQuery(v).addClass('active');
            $.ajax({
                url: "<?php echo url_for('home/get_component') ?>?component="+component,
                context: document.body,
                success: function(data){
                    $('#component_holder').html(data);
                }
            });
        });
    });
    
</script>


<?php if (!$has_course) { ?>
    <a id="teacher_lb" href="<?php echo url_for('home/assign_course_for_teacher') ?>">_</a>
    <script>
        jQuery('#teacher_lb').fancybox();
        setTimeout(function(){jQuery('#teacher_lb').click()},1000);
    </script>
<?php } ?>